<template>
	<view>
		<u-navbar :title="title" safeAreaInsetTop fixed placeholder @leftClick="goNavigateBack"></u-navbar>
		<web-view :webview-styles="webviewStyles" :src="src"></web-view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				title: this.$store.state.config.shopName,
				src: ''
			}
		},
		onLoad(e) {
			console.log(e.src ); 
			const url = decodeURIComponent(e.src || '');
			console.log(url);
			this.src = url;
			if (!e.src) {
				this.$refs.uToast.show({
					message: '网址获取失败',
					type: 'error',
					isTab: true,
					url: '/pages/index/default/default'
				});
			}
			if (e.title) {
				this.title = e.title;
			}
		},
		methods: {

		}
	}
</script>

<style lang="scss" scoped>
</style>